package com.sjzl.entity;

import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

@Entity
@Table(name="tb_updatefile")
public class UploadFile extends BaseEntity{
	
	private String uploadFileName;//上传的文件名称
	private String uploadFileType;//类型
	private String uploadRealName;//保存的文件真实名称，加了UUID
	private String serverPath;//上传文件的服务器保存路径
	private String uploadUserAccount;//上传者的账户名
	
	private Post post;
	
	public String getUploadFileName() {
		return uploadFileName;
	}
	public void setUploadFileName(String uploadFileName) {
		this.uploadFileName = uploadFileName;
	}
	public String getUploadFileType() {
		return uploadFileType;
	}
	public void setUploadFileType(String uploadFileType) {
		this.uploadFileType = uploadFileType;
	}
	public String getUploadRealName() {
		return uploadRealName;
	}
	public void setUploadRealName(String uploadRealName) {
		this.uploadRealName = uploadRealName;
	}
	public String getServerPath() {
		return serverPath;
	}
	public void setServerPath(String serverPath) {
		this.serverPath = serverPath;
	}
	public String getUploadUserAccount() {
		return uploadUserAccount;
	}
	public void setUploadUserAccount(String uploadUserAccount) {
		this.uploadUserAccount = uploadUserAccount;
	}
	
	@ManyToOne(cascade = {CascadeType.ALL})
	public Post getPost() {
		return post;
	}
	public void setPost(Post post) {
		this.post = post;
	}
	
}
